﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace weighing
{
    /// <summary>
    /// 角色虚拟类型
    /// </summary>
    public class RoleV
    {
        public Int32 Level { get; set; }
        public String Name { get; set; }


        public static List<RoleV> GetList()
        {
            List<RoleV> list = new List<RoleV>();
            if (App.CurrentUser.roleType == (int)UserRoleType.Developer)
            {
                list.Add(new RoleV() { Level = (int)UserRoleType.Developer, Name = "超级管理员" });
                list.Add(new RoleV() { Level = (int)UserRoleType.WeighingManager, Name = "管理员" });
                list.Add(new RoleV() { Level = (int)UserRoleType.Weighinger, Name = "过磅员" });
            }
            else if (App.CurrentUser.roleType == (int)UserRoleType.WeighingManager)
            {      
                list.Add(new RoleV() { Level = (int)UserRoleType.WeighingManager, Name = "管理员" });
                list.Add(new RoleV() { Level = (int)UserRoleType.Weighinger, Name = "过磅员" });
            }
            return list;
        }
    }

  
}
